﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Neoseeker.NAMFox.Tests
{
    /// <summary>
    /// Contains common XPath expressions
    /// </summary>
    public static class XPathExpressions
    {
        /// <summary>
        /// Selects the delete link for the last post on the page.
        /// </summary>
        public const string DeleteLinkForLastPostOnPage = "//table[@id='threadlist']/tbody/tr[position()=last()]/preceding-sibling::*[1]//a[text()='del']";

        /// <summary>
        /// Selects the last &lt;div&gt; element on the page that contains a post.
        /// </summary>
        public const string LastPostOnPage = "//table[@id='threadlist']/tbody/tr[position()=last()]/preceding-sibling::*[2]//div[contains(@class,'threadmsg')]";

        /// <summary>
        /// Selects the NeoPM link that appears on every page.
        /// </summary>
        public const string NeoPMLink = "//a[@class='module_link trigger']";

        /// <summary>
        /// Selects the thread closure message on a forum page.
        /// </summary>
        public const string ThreadClosureMessage = "//div[contains(@class,'forumnamearea')]/p/font/b";
    }
}
